import request from '@/plugin/axios'

export function getContentList (params) {
  return request({
    url: '/content/selectListByEnterpriseIdAndCatalogCode',
    method: 'get',
    params
  })
}

export function saveOrEdit (data) {
  return request({
    url: '/content/saveOrEdit',
    method: 'post',
    data
  })
}

export function deleteById (id) {
  return request({
    url: '/content/deleteById?id=' + id,
    method: 'get'
  })
}

export function queryDetailByContentId (id) {
  return request({
    url: '/content/selectDetailByContentId?id=' + id,
    method: 'get'
  })
}

export function saveOrEdit4Detail (data) {
  return request({
    url: '/content/saveOrEdit4Detail',
    method: 'post',
    data
  })
}
